<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
    <html>
        <head>
            <title></title>
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
            <script src="__PUBLIC__/jquery-1.7.2.min.js"></script>
        <link href="__PUBLIC__/admin/css/category.css" rel="stylesheet" type="text/css"/>  
 
    </head>
    <body>
        
        <div class='content'>
            <div class='t'>
                <if condition="isset($type['name'])">
			<h3>添加 {$type.name} 类型属性</h3>
                        <else/>
                        <h3>添加属性</h3>
                </if>
		</div>
            <form action="{:U('attrAdd')}" method="post">
                        <table>
                             <if condition="isset($type['name'])">
                                    <input name='type_id' value="{$Think.get.type_id}" type="hidden"/>
                                    <else/>
                                    <tr>
                                            <th>所属类型</th>
                                            <td>
                                                <select name="type_id">
                                                    <option>--请选择类型--</option>
                                                    <foreach name="type" item='t'>
                                                    <option value="{$t.type_id}">{$t.name}</option>
                                                    </foreach>
                                                </select>
                                            </td>
                                        </tr>
                            </if>
                             
                            <tr>
                                <th>属性名称</th>
                                <td><input type="text" name='name'/>
                                    <span class="red">*</span><span class='catname'>类型名称请使用中文、英文、下划线</span></td>
                            </tr>
                            <tr>
                                <th>属性选择</th>
                                <td>
                                    <textarea cols="40" rows="5" name='choose'></textarea>
                                    <span class="red">*</span><span class=''>请用换行符分隔不同属性</span></td>
                            </tr>
                            <tr>
                                <th>是否可选择</th>
                                <td><input type="radio" name='flag' value="0"/>可选择
                                    <input type="radio" name='flag' value="1" checked="checked"/>不可选择
                                <span class="red">*</span></td>
                            </tr>
                            <tr>
                                <td colspan="2" width="45%" align='right'><input type="submit" class="bt1" name='sub' value="添加"/></td>
                            </tr>
                        </table>
                    <div>
                        
                    </div>

            </form>
        </div>
    </body>
</html>